Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Log an error if update() call returns ERROR #1969

Merged
merged 2 commits into from
Dec 23, 2024
Merged

Conversation

christophfroehlich
Copy link
Contributor

As we discussed in #1873: On humble we do not take any action if the update call of a controller returns ERROR. As we don't want to break the behavior on humble, I suggest adding at least a log output.

I'm just not sure if we should just print it once, throttled, or on every call.

Closes #1873

@christophfroehlich christophfroehlich changed the title Give an error output Log an error if update() call returns ERROR Dec 21, 2024
@christophfroehlich christophfroehlich linked an issue Dec 21, 2024 that may be closed by this pull request
Copy link

codecov bot commented Dec 21, 2024

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 62.84%. Comparing base (4c58cda) to head (75aed5b).
Report is 1 commits behind head on humble.

Files with missing lines Patch % Lines
controller_manager/src/controller_manager.cpp 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           humble    #1969      +/-   ##
==========================================
- Coverage   62.87%   62.84%   -0.03%     
==========================================
  Files         109      109              
  Lines       12589    12590       +1     
  Branches     8549     8550       +1     
==========================================
- Hits         7915     7912       -3     
- Misses        858      861       +3     
- Partials     3816     3817       +1     
Flag Coverage Δ
unittests 62.84% <0.00%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
controller_manager/src/controller_manager.cpp 66.72% <0.00%> (-0.31%) ⬇️

Copy link
Member

@saikishor saikishor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The problem with the _ONCE is it will print once for the first controller and will never print it again.

@saikishor
Copy link
Member

@christophfroehlich like you. I'm also not sure which is the best option for this. Logging every time might spam a bit, and with throttle might miss some logs. Once might not be a good one here.

@christophfroehlich
Copy link
Contributor Author

The problem with the _ONCE is it will print once for the first controller and will never print it again.

Ah you are right. I changed it to RCLCPP_ERROR. This will influence the update rate maybe, but this is not a operating mode which should be maintained right?

Copy link
Member

@bmagyar bmagyar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it is fair to spam in this case. People should not run with a dead controller :D

@bmagyar bmagyar merged commit 5bbc0ad into humble Dec 23, 2024
13 checks passed
@bmagyar bmagyar deleted the warn_controller_error branch December 23, 2024 15:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Controllers not deactivated on error in update on Humble
3 participants